#include "config001.h"

config001 * config001::singleConfig = NULL;


config001::config001()
{
    //ctor
}

config001::~config001()
{
    //dtor
    if(singleConfig != NULL)
        delete singleConfig;
        singleConfig = NULL;

}


config001 * config001::getInstance()
{
    if(singleConfig == NULL)
    {
        singleConfig = new config001();
    }
    return singleConfig;

}

bool config001::init()
{
    m_file.open("/home/ssx/code/0118/public/BrainConfig", ios::in);
    return true;
}


bool config001::loadConfig()
{
    string key;
    string value;
    while(m_file >> key)
    {
        m_file >> value;
        configMap[key] = value;
    }

}
